<!DOCTYPE html>
<html class="pixel-ratio-1"><head>
    <meta charset="utf-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <title>茵曼商城</title>
    <meta name="viewport" content="initial-scale=1, maximum-scale=1, user-scalable=0">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <link rel="stylesheet" href="css/sm.min.css">
    <link rel="stylesheet" href="css/sm-extend.min.css">
    <link rel="stylesheet" href="css/inman.css">
    <script src="https://hm.baidu.com/hm.js?5ee51ef74fa865950bb9a2757fdb33ad"></script><script type="text/javascript" src="js/zepto.min.js" charset="utf-8"></script>
    <script type="text/javascript" src="js/sm.min.js" charset="utf-8"></script>
    <script type="text/javascript" src="js/sm-extend.js" charset="utf-8"></script>
    <script type="text/javascript" src="js/functions.js" charset="utf-8"></script>
    <script type="text/javascript" src="js/TouchSlide.1.1.js" charset="utf-8"></script>
    <script type="text/javascript" src="js/jweixin-1.0.0.js"></script>
    <script>
        var _hmt = _hmt || [];
        (function() {
            var hm = document.createElement("script");
            hm.src = "https://hm.baidu.com/hm.js?5ee51ef74fa865950bb9a2757fdb33ad";
            var s = document.getElementsByTagName("script")[0];
            s.parentNode.insertBefore(hm, s);
        })();
    </script>
    <style type="text/css">.full-html,.full-body{width: 100% !important;height: 100% !important;margin: 0 !important;overflow: hidden !important;}.full-body *{display: none !important;}.full-iframe {display: block !important;}.full-inpage {width: 100% !important;height: 100% !important;margin: 0 !important;overflow: hidden !important;background: rgb(243, 243, 247) !important;}.full-inpage > *:not(.ntalk-mobile-inpage-background) {display: none !important;}</style><script type="text/javascript" async="async" charset="utf-8" src="http://sh-trail.ntalker.com/trail/trail/userinfo.php?action=getregion&amp;siteid=kf_9154&amp;userid=kf_9154_ISME9754_1122715&amp;callback=trail_getregion_87D9615B"></script><script type="text/javascript" async="async" charset="utf-8" src="http://dl.ntalker.com/js/xn6/zh_cn.js?siteid=kf_9154&amp;v=nt6.92&amp;t=2017.08.25_011054" data-requiremodule="lang"></script><script type="text/javascript" async="async" charset="utf-8" src="http://dl.ntalker.com/js/xn6/chat.in.js?siteid=kf_9154&amp;v=nt6.92&amp;t=2017.08.25_011054" data-requiremodule="chatManage"></script><script type="text/javascript" async="async" charset="utf-8" src="http://dl.ntalker.com/js/xn6/mqtt31.js?siteid=kf_9154&amp;v=nt6.92&amp;t=2017.08.25_011054" data-requiremodule="MQTT"></script><script type="text/javascript" async="async" charset="utf-8" src="http://dl.ntalker.com/js/xn6/mqtt.chat.js?siteid=kf_9154&amp;v=nt6.92&amp;t=2017.08.25_011054" data-requiremodule="Connection"></script></head>
<body><div class="page-group address-page">
    <div class="page page-current" id="page-1510723852378">
        <!--标题栏-->
        <header class="bar bar-nav">
            <a class="icon icon-left pull-left" href="javascript:history.back(-1);"></a>

            <h1 class="title">收货地址</h1>
        </header>

        <!--内容区-->
        <div class="content native-scroll">
            <div class="box1">
                <ul>
                    <li data-addr_id="286801">
                        <h3>收货人 :信春廷<span>15910288070</span></h3>

                        <p>北京北京市通州区土桥</p>

                        <div class="operation">
                            <a data-addr-id="286801" class="is-default ">
                                设为默认                                </a>
                            <a href="#" data-delet-id="286801" class="pull-right delete">删除</a>
                            <a href="http://m.inman.com.cn/index.php/User/addAddress?addr_id=286801" data-eadit-id="286801" class="pull-right">编辑</a>

                            <div class="cb"></div>
                        </div>
                    </li>
                </ul>
            </div>
            <div class="box2">
                <a href="http://m.inman.com.cn/index.php/User/addAddress">添加收货地址</a>
            </div>
        </div>
    </div>
    <script>
        $(function () {
            //下订单选择地址
            var goto_url="";
            if(goto_url!=''){
                localStorage['goto_url']=goto_url;
            }
            $("div.box1 ul>li").click(function(){
                var address_id=$(this).data("addr_id");
                if(localStorage['goto_url']){
                    localStorage['address_id'] = address_id;
                    location.replace(localStorage['goto_url']);
                }
                event.stopPropagation();
            });

            //设置默认地址
            $("a.is-default").click(function () {
                var uri = "http://m.inman.com.cn/index.php/User/setDefaultAddress";
                var addr_id = $(this).attr('data-addr-id');
                $.showIndicator();
                $.ajax({
                    cache: true,
                    type: "POST",
                    url: uri,
                    data: {addr_id: addr_id},
                    async: false,
                    success: function (json) {
                        $.hideIndicator();
                        json = eval('(' + json + ')');
                        if (json.errcode != '1') {
                            $.toast(json.errmsg);
                            return false;
                        }
                        if (json.errcode && json.url !== '') {
                            setTimeout(function () {
                                window.location.href = "http://m.inman.com.cn/index.php/User/index";
                            }, 1000);
                        }
                    }
                });
            });

            //删除收货地址
            $("a.delete").click(function () {
                var  uri = "http://m.inman.com.cn/index.php/User/deleteAddress";
                var  addr_id = $(this).attr('data-delet-id');
                $.showIndicator();
                $.ajax({
                    cache: true,
                    type: "POST",
                    url: uri,
                    data: {addr_id: addr_id},
                    async: false,
                    success: function (json) {
                        $.hideIndicator();
                        json = eval('(' + json + ')');
                        if (json.errcode != '1') {
                            $.toast(json.errmsg);
                            return false;
                        }
                        if (json.errcode && json.url !== '') {
                            setTimeout(function () {
                                window.location.href = "http://m.inman.com.cn/index.php/User/index";
                            }, 1000);
                        }
                    }
                });
            })
        });
        $.init();
    </script>
</div><div id="nTalk_post_hiddenElement" style="left: -10px; top: -10px; visibility: hidden; display: none; width: 1px; height: 1px;"></div>



</body></html>